<?php

namespace app\admin\model;

use app\common\model\TimeModel;

class MallTradeRecordLog extends TimeModel
{
    
    protected $name = "mall_trade_record_log";
    
    protected $deleteTime = "delete_time";
    
    
    public function mallOrder()
    {
        return $this->belongsTo('\app\admin\model\MallOrder', 'order_id', 'id');
    }
    
    public function promotion()
    {
        return $this->belongsTo('\app\admin\model\MallPromotion', 'user_id', 'user_id');
    }
    
    public function user()
    {
        return $this->belongsTo('\app\admin\model\MallPromotion', 'user_id', 'user_id');
    }
    
    public function orderUser()
    {
        return $this->belongsTo('\app\admin\model\MallUser', 'order_user_id', 'id');
    }
}